package com.taxshare.manager.remote;

import com.taxshare.manager.view.dto.HumanResourcesDTO;
import com.taxshare.response.beans.Response;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * @ClassName: ApiClientService
 * @Description:
 * @author: luozhongyi
 * @date: 2021/4/1 9:35
 */
@FeignClient(name = "tax-api", fallback = ApiClientService.ApiClientServiceImpl.class)
@Component
public interface ApiClientService {

    /**
     * 【无效】该方法只是作为模板放在这
     * @param humanResourcesDTO
     * @return
     */
    @RequestMapping(value = "/manager/getResources", method = RequestMethod.POST)
    Response getResources(@RequestBody HumanResourcesDTO humanResourcesDTO);
    

    @Component
    class ApiClientServiceImpl implements ApiClientService {
        @Override
        public Response getResources(@RequestBody HumanResourcesDTO humanResourcesDTO) {
            return null;
        }

    }
}
